package com.itheima.reggie.service;

import com.itheima.reggie.common.R;
import com.itheima.reggie.entity.Employee;
import com.itheima.reggie.entity.Page;

public interface EmployeeService {

    /**
     * 登入业务方法
     * @param employee
     * @return
     */
    R<Employee> login(Employee employee);

    /**
     * 新增员工
     * @param employee
     * @return
     */
    boolean save(Employee employee);

    /**
     * 分页查询
     * @param page
     * @param pageSize
     * @param name
     * @return
     */
    Page<Employee> findByPage(Integer page,Integer pageSize,String name);

    /**
     * 修改业务方法
     * @param employee
     * @return
     */
    boolean update(Employee employee);

    /**
     * 回显数据
     * @param id
     * @return
     */
    R<Employee> findById(Long id);
}
